import { stringify } from 'qs';
import request from '@/utils/request';

// 获取客户列表（分页）
export async function SearchMemberList(params) {  
  return request(`/${window.storeId}/Member/SearchMemberList`, {
    method: 'POST',
    body: {
      ...params,
    },
  });
}


// 获取手动标签列表
export async function FindTagList(params) {
  return request(`/${window.storeId}/Member/FindTagList?${stringify(params)}`);
}

// 获取客户查询下拉标签列表
export async function FindAllTagList(params) {
  return request(`/${window.storeId}/Member/FindAllTagList?${stringify(params)}`);
}

// 获取有效会员卡列表
export async function FindCardList(params) {
  return request(`/${window.storeId}/Member/FindCardList?${stringify(params)}`);
}

// 通过会员Id获取会员信息
export async function FindMemberInfoById(params) {
  return request(`/${window.storeId}/Member/FindMemberInfoById?${stringify(params)}`);
}

// 批量添加手动标签
export async function AddMemberTags(params) {  
  return request(`/${window.storeId}/Member/AddMemberTags`, {
    method: 'POST',
    body: {
      ...params,
    },
  });
}

// 批量修改积分
export async function ChangePoints(params) {  
  return request(`/${window.storeId}/Member/ChangePoints`, {
    method: 'POST',
    body: {
      ...params,
    },
  });
}

// 修改备注
export async function ChangeRemark(params) {  
    return request(`/${window.storeId}/Member/ChangeRemark`, {
      method: 'POST',
      body: {
        ...params,
      },
    });
  }

// 批量发放会员卡
export async function AddCard(params) {  
  return request(`/${window.storeId}/Member/AddCard`, {
    method: 'POST',
    body: {
      ...params,
    },
  });
}

// 删除客户手动标签
export async function DelMemberTag(params) {  
  return request(`/${window.storeId}/Member/DelMemberTag`, {
    method: 'POST',
    body: {
      ...params,
    },
  });
}




